<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head th:include="layout :: htmlhead" th:with="title='用户列表'">
    <meta charset="UTF-8"/>
</head>
<body class="container">
<div th:replace="layout :: navbar">(navbar)</div>

<div class="container">
	<div class="starter-template">

		<h1>用户列表</h1>

		<div class="with:80%">
		    <table class="table table-hover">
		        <thead>
		        <tr>
		            <th>#</th>
		            <th>User Name</th>
		            <th>Birthday</th>
		            <th>Salary</th>
		            <th>Edit</th>
		            <th>Delete</th>
		        </tr>
		        </thead>
		        <tbody>
		        <tr  th:each="user : ${users}">
		            <th scope="row" th:text="${user.userId}">1</th>
		            <td th:text="${user.userName}">neo</td>
		            <td th:text="${user.userBirthday}">2012-01-01</td>
		            <td th:text="${user.userSalary}">6000</td>
		            <td><a th:href="@{toEdit(id=${user.userId})}">edit</a></td>
		            <td><a th:href="@{delete(id=${user.userId})}">delete</a></td>
		        </tr>
		        </tbody>
		    </table>
		</div>
		<div class="form-group">
		    <div class="col-sm-2 control-label">
		        <a href="toAdd" th:href="@{toAdd}" class="btn btn-info">add</a>
		    </div>
		</div>
    </div>
</div>

<div th:include="layout :: footer" id="footer">(footer)</div>
</body>
</html>